package com.gmzg.gmzgnews.news.entries;

import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;

import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.List;

/**
 * Created by Jasen on 2016 2016/11/4.11:04
 * Email:1142803753@qq.com
 * weixin: aserbao
 */

public class AmuseNews {

    /**
     * count : 3
     * description : 昨日，乘客王女士向华商报报料，称2日中午她从商洛市汽车站乘坐大巴车前往西安，车辆行驶到半路上，司机竟打起了盹，持续有十多分钟，之后司机又嗑起了瓜子
     * fcount : 0
     * fromname : 新华网
     * fromurl : http://news.xinhuanet.com/photo/2016-11/04/c_1119847022.htm
     * id : 14062
     * img : /top/default.jpg
     * keywords : 大巴司机打盹10分钟
     * rcount : 0
     * time : 1478223443000
     * title : 大巴司机打盹10分钟:我意识非常清醒
     * topclass : 0
     */

    private int count;
    private String description;
    private int fcount;
    private String fromname;
    private String fromurl;
    private int id;
    private String img;
    private String keywords;
    private int rcount;
    private long time;
    private String title;
    private int topclass;

    public static List<AmuseNews> arrayAmuseNewsFromData(String str) {

        Type listType = new TypeToken<ArrayList<AmuseNews>>() {
        }.getType();

        return new Gson().fromJson(str, listType);
    }

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public int getFcount() {
        return fcount;
    }

    public void setFcount(int fcount) {
        this.fcount = fcount;
    }

    public String getFromname() {
        return fromname;
    }

    public void setFromname(String fromname) {
        this.fromname = fromname;
    }

    public String getFromurl() {
        return fromurl;
    }

    public void setFromurl(String fromurl) {
        this.fromurl = fromurl;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getImg() {
        return img;
    }

    public void setImg(String img) {
        this.img = img;
    }

    public String getKeywords() {
        return keywords;
    }

    public void setKeywords(String keywords) {
        this.keywords = keywords;
    }

    public int getRcount() {
        return rcount;
    }

    public void setRcount(int rcount) {
        this.rcount = rcount;
    }

    public long getTime() {
        return time;
    }

    public void setTime(long time) {
        this.time = time;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public int getTopclass() {
        return topclass;
    }

    public void setTopclass(int topclass) {
        this.topclass = topclass;
    }
}
